package org.jftstool.auxiliar;

import java.io.File;

import org.jftstool.JFTSFramework;
import org.jftstool.exceptions.JFTSFrameworkException;
import org.jftstool.indexer.exceptions.JFTSIndexerException;

public class JFTSFrameworkTest {


	/*
	public static void main(String[] args) {
		JFTSFramework jfts = JFTSFramework.getJFTSInstance();
		try {
			jfts.startSession();
			jfts.getOntoCategorization();
			jfts.closeSession();
			
			jfts.startSession();
			JFTSResult result = jfts.simpleQuerySearch("content", "dios", null, 1, 1000);
			jfts.closeSession();			
			
			
		}
		catch (JFTSFrameworkException e) {
			e.printStackTrace();
		}
		catch (JFTSSearcherException e) {
			e.printStackTrace();
		}
	}
	*/

	
	public static void main(String[] args) {
		JFTSFramework jfts = JFTSFramework.getJFTSInstance();
		try {
			jfts.startSession();
			jfts.addDocuments(new File("c:\\Html"), true);
			//jfts.addDBDocuments("MySql", "DefaultQuery", false);
			//jfts.addDocuments(new File("c:\\HTML1G"), true);			
			jfts.closeSession();
		}
		catch (JFTSFrameworkException e) {
			e.printStackTrace();
		}
		catch (JFTSIndexerException e) {
			e.printStackTrace();
		}
	}
}

